package com.example.homwwork1.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.Random;

@Controller
public class RandomController {
    Random r = new Random();
  int RandomTest=r.nextInt(1000);
    @GetMapping("/random")
    @ResponseBody
    public int show() {
        return RandomTest;
    }
}